package com.tbit.manager.api;

import com.tbit.common.entity.view.Result;
import com.tbit.manager.api.dto.RefundReturnDTO;
import com.tbit.manager.api.dto.UserMoneyRefundDTO;
import com.tbit.manager.enums.ApiConstants;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 退款接口
 */
@FeignClient(name = ApiConstants.NAME)
public interface RefundServiceApi {

    String PREFIX = ApiConstants.PREFIX + "/refund";

    /**
     * 用户余额退款
     *
     * @param userMoneyRefundDTO .
     */
    @PostMapping(value = PREFIX + "/userMemPage", consumes = "application/json",produces = "application/json")
    Result<RefundReturnDTO> userMoneyRefund(@RequestBody UserMoneyRefundDTO userMoneyRefundDTO);
    /**
     * 退款结果查询
     *
     * @param refundBusinessNO 订单号
     */
    @GetMapping(PREFIX + "/userRideCardPage")
    Result<RefundReturnDTO> queryRefundResult(@RequestParam("refundBusinessNO") String refundBusinessNO);
}
